Updates badge text and style of the toolbar item with <span class="argument">id</span>.

<div class="definition">
    setCount(id, count, [className], [style])
</div>

<div class="arguments">
    <table>
    <tr>
        <td>id</td>
        <td><b>string</b>, id of the toolbar item</td>
    </tr>
    <tr>
        <td>count</td>
        <td><b>text</b>, count for the toolbar item, can be plain text</td>
    </tr>
    <tr>
        <td>className</td>
        <td><b>text</b>, (<i>optional</i>) custom class for the badge</td>
    </tr>
    <tr>
        <td>style</td>
        <td><b>text</b>, (<i>optional</i>) additional style for the badge</td>
    </tr>
    </table>
</div>

Returns undefined.

<h4>Description</h4>

The first argument <span class="argument">id</span> is the id of the toolbar item you used when you created toolbar items. The
<a class="method" href="w2toolbar.items">.items</a> array holds all created toolbar items.
<div style="height: 10px"></div>

If you have toolbar defined in the following way:
<textarea class="javascript">
let toolbar = new w2toolbar({
    name  : 'toolbar',
    items : [
        { type: 'button',  id: 'item1', text: 'Text A', count: 5 },
        { type: 'button',  id: 'item2', text: 'Text B', count: 6 },
        { type: 'button',  id: 'item3', text: 'Text C', count: 7 }
    ]
});
</textarea>

You can update badge by
<textarea class="javascript">
w2ui.toolbar.setCount('item1', '50', '', 'color: red');
</textarea>